package com.kh.samr.entity.expert;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.kh.samr.entity.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.*;
import java.util.Date;

/**
 * 工作履历信息
 *
 * @author Harry
 * @date 2020/12/28
 */
@ApiModel(description = "工作履历信息")
@Table(name = "ep_work_history")
@EqualsAndHashCode(callSuper = true)
@Entity
@Data
@AllArgsConstructor
@NoArgsConstructor
public class WorkHistory extends BaseEntity {
	
	private static final long serialVersionUID = 4520194973738911949L;
	
	/**
	 * 单位名称
	 */
	@ApiModelProperty(value = "单位名称", readOnly = true)
	@Column(length = 100)
	private String companyName;
	
	/**
	 * 统一社会信用代码
	 */
	@ApiModelProperty(value = "统一社会信用代码", readOnly = true)
	@Column(length = 20)
	private String uniformSocialCreditCode;
	
	/**
	 * 国家
	 */
	@ApiModelProperty(value = "国家", readOnly = true)
	@Column(length = 50)
	private String nationality;
	
	/**
	 * 职务
	 */
	@ApiModelProperty(value = "职务", readOnly = true)
	@Column(length = 100)
	private String jobTitle;
	
	/**
	 * 职称
	 */
	@ApiModelProperty(value = "职称", readOnly = true)
	@Column(length = 50)
	private String title;
	
	/**
	 * 工作性质
	 */
	@ApiModelProperty(value = "工作性质", readOnly = true)
	@Column(length = 30)
	private String workNature;
	
	/**
	 * 起始时间
	 */
	@ApiModelProperty(value = "起始时间", readOnly = true, example = "yyyy-MM-dd")
	@Temporal(TemporalType.DATE)
	@DateTimeFormat(pattern = "yyyy-MM-dd")
	@JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd")
	@Column()
	private Date startingDate;
	
	/**
	 * 结束时间
	 */
	@ApiModelProperty(value = "结束时间", readOnly = true, example = "yyyy-MM-dd")
	@Temporal(TemporalType.DATE)
	@DateTimeFormat(pattern = "yyyy-MM-dd")
	@JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd")
	private Date finishDate;
	
	/**
	 * 联系电话
	 */
	@ApiModelProperty(value = "联系电话", readOnly = true)
	@Column(length = 20)
	private String jobTelephone;
	
	/**
	 * 联系传真
	 */
	@ApiModelProperty(value = "联系传真", readOnly = true)
	@Column(length = 20)
	private String jobFax;
	
	/**
	 * 工作中研究方向
	 */
	@ApiModelProperty(value = "联系传真", readOnly = true)
	private String direction;
}
